#ifndef __SCANNER_LIBRARY_H__
#define __SCANNER_LIBRARY_H__

#ifdef __cplusplus
extern "C"{
#endif

#define __SCANNER_EXPORT __declspec(dllexport)

//barcode suffix segment
typedef enum _SCAN_DATA_SUFFIX {
	NONE_SUFFIX=-1,
	STRING_SUFFIX=0,
	NEWLINE_SUFFIX=10,		//new line
	ENTER_SUFFIX=13,		//enter
	SPACE_SUFFIX=32,		//space
}_SCAN_DATA_SUFFIX;

typedef enum BeepType
{
	SystemDefault=0xFFFFFFFF,
	SystemAsterisk=MB_ICONASTERISK,
	SystemExclamation=MB_ICONEXCLAMATION,
	SystemHand=MB_ICONHAND,
	SystemQuestion=MB_ICONQUESTION,
}BeepType;



//other API
/*
*	Param:
		sControl: Control the scanner other attribute
	Description:
		When you call Init Fuc,you should fill the struct
*/
__SCANNER_EXPORT void ScannerAutoInit();

/*
*	Description:
		When you exit your application,call this function.
*/
__SCANNER_EXPORT void ScannerAutoExit();

/*
* Param:
		hWnd: Your windows handle
		NotifyMessageId: User-self-definition-message
  Description:
		Called when scan key down
*/
__SCANNER_EXPORT void ScannerTriggerOn(void *hWnd,int NotifyMessageId);

/*
* Description:Called when scan key up
*/
__SCANNER_EXPORT void ScannerTriggerOff();

/*
* Param:
		BarcodeDataBuffer: Buffer for store barcode data
		Maxlen: Sizeof Buffer
  Description:
		Called when user-self-definition-message arrival
*/
__SCANNER_EXPORT size_t GetScanBarcode(void *BarcodeDataBuffer,size_t MaxLen);

/*
*	Description:standard keyboard output,with suffix
*/
__SCANNER_EXPORT void StandardKeyboradOut(void *BarcodeData,int Len,enum _SCAN_DATA_SUFFIX DataSuffixType);


#ifdef __cplusplus
}
#endif

#endif